//
//  LGPopWindow.m
//  UniverseProject
//
//  Created by king on 2021/6/21.
//  Copyright © 2021 Cloud2209. All rights reserved.
//


#import "KLCPopup.h"
#import "LGPopWindow.h"

@implementation LGPopWindow

SingletonM(LGPopWindow)

/// 封装了弹层样式
/// @param window 弹层的样式,底部弹出带遮罩
+ (void)showWindowBottomUp:(UIView *)window{
    KLCPopup *popB = [KLCPopup popupWithContentView:window
                                           showType:KLCPopupShowTypeSlideInFromBottom
                                        dismissType:KLCPopupDismissTypeSlideOutToBottom maskType:KLCPopupMaskTypeDimmed dismissOnBackgroundTouch:true dismissOnContentTouch:NO];
    KLCPopupLayout layout = KLCPopupLayoutMake(
                                               KLCPopupHorizontalLayoutCenter, KLCPopupVerticalLayoutBottom);
    [popB showWithLayout:layout];
}


/// 封装了弹层样式
/// @param window 弹层的样式,底部弹出带遮罩
+ (void)showWindowCenter:(UIView *)window{
    KLCPopup *popB = [KLCPopup popupWithContentView:window
                                           showType:KLCPopupShowTypeGrowIn
                                        dismissType:KLCPopupDismissTypeShrinkOut maskType:KLCPopupMaskTypeDimmed dismissOnBackgroundTouch:true dismissOnContentTouch:NO];
    KLCPopupLayout layout = KLCPopupLayoutMake(
                                               KLCPopupHorizontalLayoutCenter, KLCPopupVerticalLayoutCenter);
    [popB showWithLayout:layout];
}


@end
